package com.whh.service;

import com.whh.entity.BaseEntity;
import com.whh.entity.ResultEntity;

import java.util.List;

public interface BaseService<T extends BaseEntity> {

	T add(T entity);

	Integer del(T entity);
	
	T update(T entity);
	
	List<T> search(T entity);

	T getById(Integer id);
	
	List<T> sum(T entity);

	List<T> total(T entity);

	T init(T entity);
	
	ResultEntity searchByPage(T entity,Integer currPage, Integer pageSize);
}
